summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCharles Lombardo <clombardo169@gmail.com>2023-04-26 07:54:55 +0200
committerbunnei <bunneidev@gmail.com>2023-06-03 09:05:55 +0200
commitf41939b66e09d39c3a87ab53bf681738af59a893 (patch)
treed924353dd0be7e9ec4482becfa18cc5209c408c9
parentandroid: Fix setup rotation bug (diff)
downloadyuzu-f41939b66e09d39c3a87ab53bf681738af59a893.tar
yuzu-f41939b66e09d39c3a87ab53bf681738af59a893.tar.gz
yuzu-f41939b66e09d39c3a87ab53bf681738af59a893.tar.bz2
yuzu-f41939b66e09d39c3a87ab53bf681738af59a893.tar.lz
yuzu-f41939b66e09d39c3a87ab53bf681738af59a893.tar.xz
yuzu-f41939b66e09d39c3a87ab53bf681738af59a893.tar.zst
yuzu-f41939b66e09d39c3a87ab53bf681738af59a893.zip
-rw-r--r--src/android/app/src/main/res/layout/fragment_setup.xml8
-rw-r--r--src/android/app/src/main/res/layout/page_setup.xml60
2 files changed, 45 insertions, 23 deletions
diff --git a/src/android/app/src/main/res/layout/fragment_setup.xml b/src/android/app/src/main/res/layout/fragment_setup.xml
index adaaa4959..d7bafaea2 100644
--- a/src/android/app/src/main/res/layout/fragment_setup.xml
+++ b/src/android/app/src/main/res/layout/fragment_setup.xml
@@ -10,7 +10,9 @@
android:id="@+id/viewPager2"
android:layout_width="0dp"
android:layout_height="0dp"
- app:layout_constraintBottom_toBottomOf="parent"
+ android:clipToPadding="false"
+ android:layout_marginBottom="16dp"
+ app:layout_constraintBottom_toTopOf="@+id/button_next"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
@@ -20,7 +22,7 @@
android:id="@+id/button_next"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_margin="16dp"
+ android:layout_margin="12dp"
android:text="@string/next"
android:visibility="invisible"
app:layout_constraintBottom_toBottomOf="parent"
@@ -31,7 +33,7 @@
android:id="@+id/button_back"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
- android:layout_margin="16dp"
+ android:layout_margin="12dp"
android:text="@string/back"
android:visibility="invisible"
app:layout_constraintBottom_toBottomOf="parent"
diff --git a/src/android/app/src/main/res/layout/page_setup.xml b/src/android/app/src/main/res/layout/page_setup.xml
index 965019cdb..1436ef308 100644
--- a/src/android/app/src/main/res/layout/page_setup.xml
+++ b/src/android/app/src/main/res/layout/page_setup.xml
@@ -1,40 +1,56 @@
<?xml version="1.0" encoding="utf-8"?>
-<androidx.appcompat.widget.LinearLayoutCompat
+<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
- android:layout_height="match_parent"
- android:orientation="vertical"
- android:paddingBottom="64dp">
+ android:layout_height="match_parent">
<ImageView
android:id="@+id/icon"
- android:layout_width="220dp"
- android:layout_height="220dp"
+ android:layout_width="0dp"
+ android:layout_height="0dp"
android:layout_marginTop="64dp"
- android:layout_gravity="center" />
+ android:layout_marginBottom="32dp"
+ app:layout_constraintBottom_toTopOf="@+id/text_title"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintHeight_max="220dp"
+ app:layout_constraintHeight_min="110dp"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintTop_toTopOf="parent"
+ app:layout_constraintVertical_chainStyle="spread"
+ app:layout_constraintWidth_max="220dp"
+ app:layout_constraintWidth_min="110dp"
+ app:layout_constraintVertical_weight="3" />
<com.google.android.material.textview.MaterialTextView
- style="@style/TextAppearance.Material3.DisplayMedium"
android:id="@+id/text_title"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginTop="64dp"
+ style="@style/TextAppearance.Material3.DisplayMedium"
+ android:layout_width="0dp"
+ android:layout_height="0dp"
android:textAlignment="center"
android:textColor="?attr/colorOnSurface"
android:textStyle="bold"
+ app:layout_constraintBottom_toTopOf="@+id/text_description"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintTop_toBottomOf="@+id/icon"
+ app:layout_constraintVertical_weight="1.3"
tools:text="@string/welcome" />
<com.google.android.material.textview.MaterialTextView
- style="@style/TextAppearance.Material3.TitleLarge"
android:id="@+id/text_description"
- android:layout_width="match_parent"
- android:layout_height="wrap_content"
- android:layout_marginTop="24dp"
- android:paddingHorizontal="32dp"
+ style="@style/TextAppearance.Material3.TitleLarge"
+ android:layout_width="0dp"
+ android:layout_height="0dp"
android:textAlignment="center"
android:textSize="26sp"
+ android:paddingHorizontal="16dp"
+ app:layout_constraintBottom_toTopOf="@+id/button_action"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintTop_toBottomOf="@+id/text_title"
+ app:layout_constraintVertical_weight="2"
app:lineHeight="40sp"
tools:text="@string/welcome_description" />
@@ -42,11 +58,15 @@
android:id="@+id/button_action"
android:layout_width="wrap_content"
android:layout_height="56dp"
- android:layout_marginTop="96dp"
- android:layout_gravity="center"
android:textSize="20sp"
- app:iconSize="24sp"
+ android:layout_marginTop="16dp"
+ android:layout_marginBottom="48dp"
app:iconGravity="end"
+ app:iconSize="24sp"
+ app:layout_constraintBottom_toBottomOf="parent"
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintTop_toBottomOf="@+id/text_description"
tools:text="Get started" />
-</androidx.appcompat.widget.LinearLayoutCompat>
+</androidx.constraintlayout.widget.ConstraintLayout>